
public class BaseObject : IDispose
{
    private static int gId = 100;
    private int _guId = 0;

    public int guid
    {
        get
        {
            if (_guId == 0)
            {
                _guId = newGuid;
            }
            return _guId;
        }
    }

    public static int newGuid
    {
        get
        {
            return gId++;
        }
    }

    public void Broadcast(int type,string data = null){
        EventListener.Broadcast<string>(type,data);
    }

    virtual public void Dispose(){
        _guId = 0;
    }
}